package com.cqrt.entity;

import com.cqrt.constant.RTTableTypeConstant;
import com.ty.basic.constant.TableTypeConstrant;
import com.ty.basic.entity.CTyEntityBaseDO;
import com.ty.basic.util.TyOtype;
import lombok.Data;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.math.BigInteger;

@Data
@Entity
@Table(name = "RT_PRJ_PRECONSTRAINT")
@TyOtype(
        displayName = RTTableTypeConstant.PRECONSTRAINT_TYPE
)
public class RTPreConstraintDO extends CTyEntityBaseDO {

    /**
     * 主键 OID
     */
    @Id
    @Column(name = "OID", nullable = false, precision = 0)
    private BigInteger oid;

    /**
     * 类型字段 OTYPE
     */
    @TyOtype(
            name = RTTableTypeConstant.PRECONSTRAINT_TYPE
    )
    @Column(name = "OTYPE", length = 255)
    private String otype=RTTableTypeConstant.PRECONSTRAINT_TYPE;


    /**
     * 主项目ID
     */
    @Column(name = "APOID", precision = 0)
    private BigInteger apoid;

    /**
     * 主项目类型
     */
    @TyOtype(
            name = TableTypeConstrant.TY_PROJECT_TYPE
    )
    @Column(name = "APOTYPE", length = 255)
    private String apotype=TableTypeConstrant.TY_PROJECT_TYPE;

    /**
     * 从项目ID
     */
    @Column(name = "BPOID", precision = 0)
    private BigInteger bpoid;

    /**
     * 从项目类型
     */
    @TyOtype(
            name = TableTypeConstrant.TY_PROJECT_TYPE
    )
    @Column(name = "BPOTYPE", length = 255)
    private String bpotype=TableTypeConstrant.TY_PROJECT_TYPE;

    /**
     *主任务ID
     */
    @Column(name = "AJOID", precision = 0)
    private BigInteger ajoid;

    /**
     * 主任务类型
     */
    @TyOtype(
            name = TableTypeConstrant.TY_JOB_OTYPE
    )
    @Column(name = "AJOTYPE", length = 255)
    private String ajotype= TableTypeConstrant.TY_JOB_OTYPE;

    /**
     *从任务ID
      */
    @Column(name = "BJOID", precision = 0)
    private BigInteger bjoid;

    /**
     * 从任务类型
     */
    @TyOtype(
            name =  TableTypeConstrant.TY_JOB_OTYPE
    )
    @Column(name = "BJOTYPE", length = 255)
    private String bjotype= TableTypeConstrant.TY_JOB_OTYPE;

    @Column(name = "APNAME", length = 255)
    private String apname;

    @Column(name = "BPNAME", length = 255)
    private String bpname;

    @Column(name = "AJNAME", length = 255)
    private String ajname;

    @Column(name = "BJNAME", length = 255)
    private String bjname;
}